{% extends "base.html" %}
{% block content %}
<div class="container mt-4">
    <h2>{{ title }}</h2>
    <form method="post">
        {% csrf_token %}
        <div class="mb-3">
            <label for="id_title" class="form-label">项目名称:</label>
            <input type="text" class="form-control" id="id_title" name="title">
        </div>
        <div class="mb-3">
            <label for="id_description" class="form-label">描述:</label>
            <textarea class="form-control" id="id_description" name="description" rows="10"></textarea>
        </div>
        <div class="mb-3">
            <label for="id_start_date" class="form-label">开始日期:</label>
            <input type="date" class="form-control" id="id_start_date" name="start_date">
        </div>
        <div class="mb-3">
            <label for="id_end_date" class="form-label">截止日期:</label>
            <input type="date" class="form-control" id="id_end_date" name="end_date">
        </div>
        <div class="mb-3 form-check">
            <input type="checkbox" class="form-check-input" id="id_completed" name="completed">
            <label class="form-check-label" for="id_completed">是否完成:</label>
        </div>
        <button type="submit" class="btn btn-success">保存</button>
        <a href="{% url 'project_list' %}" class="btn btn-secondary">取消</a>
    </form>
</div>
{% endblock %}
